import { createRouter, createWebHistory} from "vue-router";

const routes = [
    {
        path: '/',
        redirect: '/today',
    },
    {
        path: '/today',
        name: 'today',
        component: () => import('@/views/Today.vue'),
    },
    {
        path: '/discovery',
        name: 'discovery',
        component: () => import('@/views/Discovery.vue'),
    },
    {
        path: '/bookmarks',
        name: 'bookmarks',
        component: () => import('@/views/Bookmarks.vue'),
    },
    {
        path: '/my',
        name: 'my',
        component: () => import('@/views/My.vue'),
    },
    {
        path: '/details/:id', 
        name: 'details',
        component: () => import('@/views/Details.vue')
      }
]

const router = createRouter({
    history: createWebHistory(import.meta.env.BASE_URL),
    routes
}
)

export default router;